<?php
$group_name = $this->formText('group_name', $this->group_name);
$btnSubmit = $this->formSubmit('submit', 'Save', array('class'=>'button'));
?>

<div class="deal">	
	<div class="deal_content_top"></div>
	<div class="deal_content">
    <?php foreach($this->errors as $error): ?>
    <div class="message"><?php echo $error ?></div>
    <?php endforeach ?>

    <form id="add-form" action="<?php echo $this->url(array("module" => "admin_user", "controller" => "group", "action" => "addpost")) ?>" method="post">
        <table style="width: 100%">
            <tr>
                <td style="width: 20%">Tên nhóm</td>
                <td><?php echo $group_name ?></td>
            </tr>
            <tr>
            	<td style="width: 20%; vertical-align: top;">Quyền</td>
            	<td style="width: auto">
            		<?php
            		$i = 0;
		            $length = count($this->controls);
		            for(; $i < $length; $i++)
           			{
           				echo "<label><input type='checkbox' name='control[]' value='{$this->controls[$i]->control_id}' />{$this->controls[$i]->control_name}</label>&nbsp;&nbsp;&nbsp;&nbsp;<br />";
           			}
            		?>
				</td>
			</tr>
            <tr>
                <td style="width: 20%">&nbsp;</td>
                <td><?php echo $btnSubmit ?></td>
            </tr>
        </table>
    </form>
	</div>
	<div class="deal_content_bottom"></div>
</div>
